#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using pii = pair<int, int>;
#define rep(i, a, b) for (int i = (a); i <= (b); i++)
#define per(i, a, b) for (int i = (a); i >= (b); i--)
#define endl '\n'
const int N = 205;

int n, m;
int f[N];
struct Edge {
  int l, r;
} a[N];
char ans[N];

void init(int n) { rep(i, 1, n) f[i] = i; }
int find(int x) { return f[x] == x ? x : f[x] = find(f[x]); }
bool check(int x, int y) {
  int fx = find(x), fy = find(y);
  return fx == fy;
}
bool merge(int x, int y) {
  int fx = find(x), fy = find(y);
  if (fx == fy) return false;
  f[fy] = fx;
  return true;
}
bool diff(int i, int j) {
  if (a[j].r > a[i].r && a[j].l > a[i].l && a[j].l < a[i].r) return true;
  if (a[i].r > a[j].r && a[i].l > a[j].l && a[i].l < a[j].r) return true;
  return false;
}

void solve() {
  cin >> n >> n;
  rep(i, 1, n) {
    cin >> a[i].l >> a[i].r;
    if (a[i].l > a[i].r) swap(a[i].l, a[i].r);
  }
  init(n * 2);
  rep(i, 1, n) rep(j, 1, i - 1) {
    if (diff(i, j)) {
      if (check(i, j)) {
        cout << "Impossible";
        return;
      }
      merge(i, j + n), merge(i + n, j);
    }
  }
  // group ower 1-n
  rep(i, 1, n) {
    if (find(i) <= n)
      cout << 'i';
    else
      cout << 'o';
  }
  return;
}
int main() {
  ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  int t = 1;
  while (t--) solve();
  return 0;
}